const dbConfig = require('../config/db.config')
const Sequelize = require('sequelize')

const sequelize = new Sequelize(
    dbConfig.DB,
    dbConfig.USER,
    dbConfig.PASSWORD,
    {
        host: dbConfig.HOSt,
        dialect: dbConfig.dialect
    }
)
const db = {
    sequelize: sequelize,
    Sequelize: Sequelize,
    tutorials: require('./turtorial.model')(sequelize, Sequelize)
}

module.exports = db
